import { h } from 'vue';

const hList = [1, 2, 3, 4, 5, 6];

function Funciton (props, context) {
    console.log(props, context);
    const { slots, attrs } = context;
    var level = 1;
    if (hList.includes(props.level)) {
        level = props.level;
    }
    return (
        <div>
            {props.msg} -----
            {
                h(`h${level}`, attrs, slots.default())
            }
        </div>
    );
}

export default Funciton;
